import Vue from 'vue'

// import Bar from "../views/Bar.vue";
// import Foo from "../views/Foo.vue";
// import NotFound from "../views/NotFound.vue";

import AppSon from "../views/AppSon.vue";

import VueRouter from "vue-router";

Vue.use(VueRouter)


//创建和引入页面文件 修改为使用 import 导入
// const Foo={template:" <div>foo</div>"}
// const Bar={template:" <div>bar</div>"}

const routes =[
  // {path:'/',redirect:'/bar/1'},
    // {path:"/foo",component:Foo,name:'reset'},
  //   {path:"/bar/:id",component:Bar},
  //   {path:"*",component:NotFound},
  {path:'/appson/:id',component:AppSon},
  { path: '/', redirect: '/appson/index' },
  ]
  
  const router =new VueRouter({
    routes,
    mode:'hash',

  })
  
  Vue.config.productionTip=false

 export default router;
  

